import request from '@/utils/request'

// 查询健康/行程码列表
export function listHealthCode(query) {
  return request({
    url: '/system/healthCode/list',
    method: 'get',
    params: query
  })
}

// 查询健康/行程码详细
export function getHealthCode(userId) {
  return request({
    url: '/system/healthCode/' + userId,
    method: 'get'
  })
}

// 查询健康/行程码数据
export function getHealthCodeData(query) {
  return request({
    url: '/system/healthCode/getData',
    method: 'get',
    params: query
  })
}

// 新增健康/行程码
export function addHealthCode(data) {
  return request({
    url: '/system/healthCode',
    method: 'post',
    data: data
  })
}

// 修改健康/行程码
export function updateHealthCode(data) {
  return request({
    url: '/system/healthCode',
    method: 'put',
    data: data
  })
}

// 删除健康/行程码
export function delHealthCode(userId) {
  return request({
    url: '/system/healthCode/' + userId,
    method: 'delete'
  })
}
